<?php
echo ($a ="20160128124719test01098f6bcd4621d373cade4e832627b4f6");
echo "   ";
echo md5($a);
exit;
	$url = "http://www.beeasy.com.cn/api/";
	$post_data = array(
		'date' => "20151201121212",
		'userName' => 'test',
		'sign' => strtoupper(md5('20151201121212test098f6bcd4621d373cade4e832627b4f6')),
		'request' => 'goods'	
	);


	$data = array(
		'goods' => array(

			array(
				'goods_id' => 2,
				'itemNo' => '24323',
				'gno' => 1,
				'ciqGno' => 1,
				'codeTs' => 1,
				'gcode' => 1,
				'gname' => 1,
				'gmodel' => 1,
				'ciqGmodel' => 1,
				'element' => 1,
				'barCode' => 1,
				'unit_1' => 1,
				'currency_1' => 1,
				'price' => 10,
				'trafMode' => 1,
				'shipName' => 1,
				'billNo' => 1,
				'weight' => 1,
				'goods_price' => 1,
			)

		)
	);

	$post_data['data'] = base64_encode(json_encode($data));
	
	$test_data = "date=20160128095927&userName=test01&version=1.0&request=goods&sign=C541831BC7B8B2AD8783187E4FB4F141&data=eyJnb29kcyI6W3siYmFyQ29kZSI6ImJhcjEwMDAwMSIsImJpbGxObyI6IiIsImJyYW5kIjoizt4iLCJjZXJ0aWZpY2F0aW9uIjoiIiwiY2lxR21vZGVsIjoiSW5zU3BlMTAwMDAxIiwiY2lxR25vIjoiSW5zMTAwMDAxIiwiY29kZVRzIjoiIiwiY3VycmVuY3lfMSI6IjE0MiIsImVsZW1lbnQiOiIiLCJlbnRlcnByaXNlc0NvdW50cnkiOiIiLCJlbnRlcnByaXNlc05hbWUiOiIiLCJmb29kRW50ZXJwcmlzZU51bWJlciI6IiIsImdjb2RlIjoiQ3VzTm8xMDAwMDEiLCJnaWZ0RmxhZyI6MCwiZ21vZGVsIjoiQ3VzU3BlMTAwMDAxIiwiZ25hbWUiOiK+xbbk1MbDwLDX7O6w38Pmy6oiLCJnbm8iOiJDdXMxMDAwMDEiLCJnb29kc19pZCI6IjYyIiwiZ29vZHNfcHJpY2UiOjAuMDEsImluc3BlY3Rpb25GbGFnIjoxLCJpdGVtTm8iOiIxMDAwMDEiLCJub3RlXzEiOiIiLCJvcmlnaW5Db3VudHJ5IjoiIiwicHJpY2UiOjAuMDEsInNoaXBOYW1lIjoiIiwic3RhbmRhcmRzIjoiIiwic3RhdHVzX2hhaWd1YW4iOjEsInN0YXR1c19zaGFuZ2ppYW4iOjEsInN0b3JhZ2UiOiIiLCJzdG9yZV9uYW1lIjoixa7N9b/nvrO5uiIsInN1cGVydmlzaW9uRmxhZyI6IjAyMDEiLCJzdXBwbGllckNvdW50cnkiOiIiLCJzdXBwbGllck5hbWUiOiIiLCJ0cmFmTW9kZSI6IiIsInVuaXRfMSI6IjAzNiIsInZveWFnZU5vIjoiIiwid2FybmluZ0ZsYWciOjEsIndlaWdodCI6IjAuMSJ9XX0=
";

	echo md5("20160218095927test01098f6bcd4621d373cade4e832627b4f6") ;
	parse_str($test_data,$arr);

	print_r($post_data);

	$ch = curl_init();
	curl_setopt($ch, CURLOPT_URL, $url);
	curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
	curl_setopt($ch, CURLOPT_POST, 1);
	curl_setopt($ch, CURLOPT_POSTFIELDS, $arr);
	$output = curl_exec($ch);
	curl_close($ch);
	print_r($output);
?>
